package com.aidebar.greendaotest.gen;

import java.util.Map;

import org.greenrobot.greendao.AbstractDao;
import org.greenrobot.greendao.AbstractDaoSession;
import org.greenrobot.greendao.database.Database;
import org.greenrobot.greendao.identityscope.IdentityScopeType;
import org.greenrobot.greendao.internal.DaoConfig;

import com.china.snapshot.bean.DBBeanUpLoadVideoInfo;
import com.china.snapshot.bean.DBUserBean;
import com.china.snapshot.bean.HttpBeanMediaDetail;
import com.china.snapshot.bean.HttpBeanMediaLikeDetail;
import com.china.snapshot.bean.LocalMediaDetailBean;

import com.aidebar.greendaotest.gen.DBBeanUpLoadVideoInfoDao;
import com.aidebar.greendaotest.gen.DBUserBeanDao;
import com.aidebar.greendaotest.gen.HttpBeanMediaDetailDao;
import com.aidebar.greendaotest.gen.HttpBeanMediaLikeDetailDao;
import com.aidebar.greendaotest.gen.LocalMediaDetailBeanDao;

// THIS CODE IS GENERATED BY greenDAO, DO NOT EDIT.

/**
 * {@inheritDoc}
 * 
 * @see org.greenrobot.greendao.AbstractDaoSession
 */
public class DaoSession extends AbstractDaoSession {

    private final DaoConfig dBBeanUpLoadVideoInfoDaoConfig;
    private final DaoConfig dBUserBeanDaoConfig;
    private final DaoConfig httpBeanMediaDetailDaoConfig;
    private final DaoConfig httpBeanMediaLikeDetailDaoConfig;
    private final DaoConfig localMediaDetailBeanDaoConfig;

    private final DBBeanUpLoadVideoInfoDao dBBeanUpLoadVideoInfoDao;
    private final DBUserBeanDao dBUserBeanDao;
    private final HttpBeanMediaDetailDao httpBeanMediaDetailDao;
    private final HttpBeanMediaLikeDetailDao httpBeanMediaLikeDetailDao;
    private final LocalMediaDetailBeanDao localMediaDetailBeanDao;

    public DaoSession(Database db, IdentityScopeType type, Map<Class<? extends AbstractDao<?, ?>>, DaoConfig>
            daoConfigMap) {
        super(db);

        dBBeanUpLoadVideoInfoDaoConfig = daoConfigMap.get(DBBeanUpLoadVideoInfoDao.class).clone();
        dBBeanUpLoadVideoInfoDaoConfig.initIdentityScope(type);

        dBUserBeanDaoConfig = daoConfigMap.get(DBUserBeanDao.class).clone();
        dBUserBeanDaoConfig.initIdentityScope(type);

        httpBeanMediaDetailDaoConfig = daoConfigMap.get(HttpBeanMediaDetailDao.class).clone();
        httpBeanMediaDetailDaoConfig.initIdentityScope(type);

        httpBeanMediaLikeDetailDaoConfig = daoConfigMap.get(HttpBeanMediaLikeDetailDao.class).clone();
        httpBeanMediaLikeDetailDaoConfig.initIdentityScope(type);

        localMediaDetailBeanDaoConfig = daoConfigMap.get(LocalMediaDetailBeanDao.class).clone();
        localMediaDetailBeanDaoConfig.initIdentityScope(type);

        dBBeanUpLoadVideoInfoDao = new DBBeanUpLoadVideoInfoDao(dBBeanUpLoadVideoInfoDaoConfig, this);
        dBUserBeanDao = new DBUserBeanDao(dBUserBeanDaoConfig, this);
        httpBeanMediaDetailDao = new HttpBeanMediaDetailDao(httpBeanMediaDetailDaoConfig, this);
        httpBeanMediaLikeDetailDao = new HttpBeanMediaLikeDetailDao(httpBeanMediaLikeDetailDaoConfig, this);
        localMediaDetailBeanDao = new LocalMediaDetailBeanDao(localMediaDetailBeanDaoConfig, this);

        registerDao(DBBeanUpLoadVideoInfo.class, dBBeanUpLoadVideoInfoDao);
        registerDao(DBUserBean.class, dBUserBeanDao);
        registerDao(HttpBeanMediaDetail.class, httpBeanMediaDetailDao);
        registerDao(HttpBeanMediaLikeDetail.class, httpBeanMediaLikeDetailDao);
        registerDao(LocalMediaDetailBean.class, localMediaDetailBeanDao);
    }
    
    public void clear() {
        dBBeanUpLoadVideoInfoDaoConfig.clearIdentityScope();
        dBUserBeanDaoConfig.clearIdentityScope();
        httpBeanMediaDetailDaoConfig.clearIdentityScope();
        httpBeanMediaLikeDetailDaoConfig.clearIdentityScope();
        localMediaDetailBeanDaoConfig.clearIdentityScope();
    }

    public DBBeanUpLoadVideoInfoDao getDBBeanUpLoadVideoInfoDao() {
        return dBBeanUpLoadVideoInfoDao;
    }

    public DBUserBeanDao getDBUserBeanDao() {
        return dBUserBeanDao;
    }

    public HttpBeanMediaDetailDao getHttpBeanMediaDetailDao() {
        return httpBeanMediaDetailDao;
    }

    public HttpBeanMediaLikeDetailDao getHttpBeanMediaLikeDetailDao() {
        return httpBeanMediaLikeDetailDao;
    }

    public LocalMediaDetailBeanDao getLocalMediaDetailBeanDao() {
        return localMediaDetailBeanDao;
    }

}
